project( ICETHREAD )
cmake_minimum_required( VERSION 2.6 )
set( LOCATION_DIR /opt/local )
set( CMAKE_CXX_FLAGS )
set( CMAKE_LIBRARY_OUTPUT_DIRECTORY ${LOCATION_DIR}/lib )
set( CMAKE_INSTALL_PREFIX ${LOCATION_DIR} )
add_definitions( -O2 -Wall -DUSE_NET_BYTE )


#include_directories( ${LOCATION_DIR}/thread )
aux_source_directory( . ICE_THREAD_DIR )

add_library( icethread SHARED ${ICE_THREAD_DIR} )
set_target_properties( icethread    PROPERTIES VERSION 1.0 SOVERSION 1 )

INSTALL ( FILES Shared.h Cond.h Config.h Exception.h Handle.h Lock.h IceUtilException.h 
    Monitor.h Mutex.h Singleton.h TaskManager.h Time.h ThreadException.h Thread.h
    DESTINATION ${LOCATION_DIR}/include/thread )
